package com.mmall.concurrency;
import	java.io.PrintWriter;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;
import java.util.stream.Stream;

/**
 * @Author:LiuWei
 * @Description:
 * @Date: Created in 20:00 2019/7/10
 * @Modified By:
 */
public class ArraysDemo {
    public static void main(String[] args) {
        String[] strs = new String[5];
//        for(int i = 0;i<4;i++){
//            strs[i] = String.valueOf(i+1);
//        }
        for (int i = 0;i < strs.length; i++){
            strs [i] = String.valueOf(i+1);
        }
        List<String> stringList =new ArrayList<>(Arrays.asList(strs));
        stringList.add("10");
       stringList.forEach(System.out::println);
        //strs[4] = "5";
       // List<String> stringList = Stream.of(strs).collect(Collectors.toList());
        //List<String> stringList = Arrays.stream(strs).collect(Collectors.toList());
        //System.out.println(stringList.getClass());


    }
}
